#include "Compiler/compiler.h"

using namespace std;

int main()
{
    cout << "Enter \"quit\" to quit" << endl;
    while(true) {
        string str;
        cout << "Enter: ";
        getline(cin, str);
        if(str == "quit")
            break;
        bool ok;
        double res = Compiler::parse(str, &ok);
        if(ok) {
            cout << res << endl;
        } else cout << "Wrong" << endl;
    }
    return 0;
}
